forked from grpc/grpc-go
-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Implement A72: OpenTelemetry Tracing #9
Open
aranjans
wants to merge
57
commits into
master
Choose a base branch
from
a72
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
aranjans
force-pushed
the
a72
branch
10 times, most recently
from
November 17, 2024 16:39
801a40f
to
db38566
Compare
aranjans
force-pushed
the
a72
branch
5 times, most recently
from
November 17, 2024 17:01
51ec59e
to
18b1e12
Compare
aranjans
force-pushed
the
a72
branch
3 times, most recently
from
November 21, 2024 17:44
378ddd3
to
8cb8222
Compare
…y_test to opentelemetry
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Overview
This pull request implements the OpenTelemetry tracing support in the gRPC-Go library as outlined in proposal A72. The implementation provides a robust framework for tracing gRPC calls using OpenTelemetry, facilitating a smooth migration path from OpenCensus tracing.
Key Features
OpenTelemetry Tracing API: Introduces a new API for enabling and configuring OpenTelemetry tracing within gRPC. This includes the addition of TraceOptions in the Options struct to allow users to specify their TraceProvider.
Context Propagation: Implements context propagation between gRPC clients and servers using OpenTelemetry's TextMapPropagator. This ensures that trace context is correctly passed along with RPC calls.
Migration Path: Provides a clear migration path from OpenCensus to OpenTelemetry, allowing users to transition their tracing implementations without breaking existing functionality. This includes support for both cross-process and in-binary migration scenarios.
Tracing Information: Captures detailed tracing information during the RPC lifecycle, including events for outbound and inbound messages, retries, and load balancer delays. This information is essential for monitoring and debugging distributed systems.
GrpcTraceBinPropagator: This is being done by @purnesh42H and PR is under review.
Implementation Details
TraceOptions Struct: A new struct has been added to the opentelemetry package to hold trace-related options, including the TraceProvider.
Event Logging: The implementation logs various events during the RPC lifecycle, such as message sizes and sequence numbers, which are crucial for understanding the flow of data through the system.
Interceptors: The existing gRPC infrastructure for interceptors has been leveraged to implement the tracing functionality, ensuring that the new features integrate seamlessly with the current architecture.
Backward Compatibility: The implementation maintains backward compatibility with existing OpenCensus tracing, allowing users to continue using the grpc-census plugin while they transition to OpenTelemetry.
RELEASE NOTES: